home *** CD-ROM | disk | FTP | other *** search
/ PC Direct 1998 August / PC Direct August 1998.iso / S / powerj / Product / hpp.z / woleguid.hpp < prev    next >
Encoding:
C/C++ Source or Header  |  1997-11-25  |  3.3 KB  |  88 lines

  1. /* %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  2.    %     Copyright (C) 1994, by WATCOM International Inc.  All rights    %
  3.    %     reserved.  No part of this software may be reproduced or        %
  4.    %     used in any form or by any means - graphic, electronic or       %
  5.    %     mechanical, including photocopying, recording, taping or        %
  6.    %     information storage and retrieval systems - except with the     %
  7.    %     written permission of WATCOM International Inc.                 %
  8.    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  9. */
  10.  
  11. #ifndef _WOLEGUID_HPP_INCLUDED
  12. #define _WOLEGUID_HPP_INCLUDED
  13.  
  14. #ifndef _WNO_PRAGMA_PUSH
  15. #pragma pack(push,8);
  16. #pragma enum int;
  17. #endif
  18.  
  19. #ifndef _stdole_HPP_INCLUDED
  20. #   include "wstdole.hpp"
  21. #endif
  22. #ifndef _WOLETYPE_HPP_INCLUDED
  23. #   include "woletype.hpp"
  24. #endif
  25.  
  26. class WCMCLASS WOleWGUIDManager {
  27.  
  28.     public:
  29.  
  30.         /**************************************************************
  31.          * Static Methods
  32.          **************************************************************/
  33.  
  34.         // GUID conversions
  35.         static void WGUIDToGUID( const WGUID & wguidSrc, GUID & guid );
  36.         static void GUIDToWGUID( const GUID & guidSrc, WGUID & wguid );
  37.  
  38.         // WString conversions
  39.         static WBool WGUIDToWString( const WGUID & wguidSrc, WString & str );
  40.         static WBool GUIDToWString( const GUID & guidSrc, WString & str );
  41.  
  42.         static WBool WStringToWGUID( const WString & strSrc, WGUID & wguid );
  43.         static WBool WStringToGUID( const WString & strSrc, GUID & guid );
  44.  
  45.         // ProgID conversions
  46.         static WBool WGUIDToProgID( const WGUID & wguidSrc, WString & progID );
  47.         static WBool GUIDToProgID( const GUID & guidSrc, WString & progID );
  48.  
  49.         static WBool ProgIDToWGUID( const WString & progIDSrc, WGUID & wguid );
  50.         static WBool ProgIDToGUID( const WString & progIDSrc, GUID & guid );
  51.  
  52.         static WBool GenerateGUID( GUID & guid );
  53.         static WBool GenerateWGUID( WGUID & wguid );
  54.  
  55.         static WBool IsNull( GUID & guid );
  56.         static WBool IsNull( WGUID & wguid );
  57.  
  58. };
  59.  
  60. extern WBool WEXPORT operator==(const WGUID& wguid, const GUID& guid );
  61. extern WBool WEXPORT operator!=(const WGUID& wguid, const GUID& guid );
  62.  
  63. extern WBool WEXPORT operator==(const GUID& guid, const WGUID& wguid );
  64. extern WBool WEXPORT operator!=(const GUID& guid, const WGUID& wguid );
  65.  
  66. extern WBool WEXPORT WOleIsEqualGUID( const GUID & guid1, const GUID & guid2 );
  67. #define WOleIsEqualCLSID WOleIsEqualGUID
  68. #define WOleIsEqualIID WOleIsEqualGUID
  69.  
  70. extern WHRESULT WEXPORT WOleLoadRegTypeLib( const GUID & rguid,
  71.                                             unsigned short wVerMajor,
  72.                                             unsigned short wVerMinor,
  73.                                             unsigned long lcid,
  74.                                             ITypeLib **pptlib );
  75.  
  76. extern WHRESULT WEXPORT WOleDispGetIDsOfNames( ITypeInfo *ptinfo,
  77.                                                long char **rgszNames,
  78.                                                unsigned int cNames,
  79.                                                long *rgdispid);
  80.  
  81. #ifndef _WNO_PRAGMA_PUSH
  82. #pragma enum pop;
  83. #pragma pack(pop);
  84. #endif
  85.  
  86. #endif // _WOLEGUID_HPP_INCLUDED
  87.  
  88.